package com.sk.sourcecircle.entity;

import android.os.Parcel;
import android.os.Parcelable;

import java.util.List;

/**
 * Created by sk on 2017/12/9.
 */

public class HomeTabList {


    /**
     * code : 200
     * data : [{"cate_id":11,"cate_name":"小区","parent_id":1,"img_url":null,"orders":0,"update_time":"1970-01-01 08:00:00","create_time":"1970-01-01 08:00:00"},{"cate_id":12,"cate_name":"户外","parent_id":1,"img_url":null,"orders":0,"update_time":"1970-01-01 08:00:00","create_time":"1970-01-01 08:00:00"},{"cate_id":13,"cate_name":"创业","parent_id":1,"img_url":null,"orders":0,"update_time":"1970-01-01 08:00:00","create_time":"1970-01-01 08:00:00"},{"cate_id":14,"cate_name":"娱乐","parent_id":1,"img_url":null,"orders":0,"update_time":"1970-01-01 08:00:00","create_time":"1970-01-01 08:00:00"}]
     */

    private int code;
    private List<DataBean> data;

    public int getCode() {
        return code;
    }

    public void setCode(int code) {
        this.code = code;
    }

    public List<DataBean> getData() {
        return data;
    }

    public void setData(List<DataBean> data) {
        this.data = data;
    }

    public static class DataBean implements Parcelable {
        /**
         * cate_id : 11
         * cate_name : 小区
         * parent_id : 1
         * img_url : null
         * orders : 0
         * update_time : 1970-01-01 08:00:00
         * create_time : 1970-01-01 08:00:00
         */

        private int cate_id;
        private String cate_name = "";
        private int parent_id;
        private String  img_url = "";
        private int orders;
        private String update_time = "";
        private String create_time = "";

        public int getCate_id() {
            return cate_id;
        }

        public void setCate_id(int cate_id) {
            this.cate_id = cate_id;
        }

        public String getCate_name() {
            return cate_name;
        }

        public void setCate_name(String cate_name) {
            this.cate_name = cate_name;
        }

        public int getParent_id() {
            return parent_id;
        }

        public void setParent_id(int parent_id) {
            this.parent_id = parent_id;
        }

        public String getImg_url() {
            return img_url;
        }

        public void setImg_url(String img_url) {
            this.img_url = img_url;
        }

        public int getOrders() {
            return orders;
        }

        public void setOrders(int orders) {
            this.orders = orders;
        }

        public String getUpdate_time() {
            return update_time;
        }

        public void setUpdate_time(String update_time) {
            this.update_time = update_time;
        }

        public String getCreate_time() {
            return create_time;
        }

        public void setCreate_time(String create_time) {
            this.create_time = create_time;
        }

        @Override
        public int describeContents() {
            return 0;
        }

        @Override
        public void writeToParcel(Parcel dest, int flags) {
            dest.writeInt(this.cate_id);
            dest.writeString(this.cate_name);
            dest.writeInt(this.parent_id);
            dest.writeString(this.img_url);
            dest.writeInt(this.orders);
            dest.writeString(this.update_time);
            dest.writeString(this.create_time);
        }

        public DataBean() {
        }

        protected DataBean(Parcel in) {
            this.cate_id = in.readInt();
            this.cate_name = in.readString();
            this.parent_id = in.readInt();
            this.img_url = in.readString();
            this.orders = in.readInt();
            this.update_time = in.readString();
            this.create_time = in.readString();
        }

        public static final Parcelable.Creator<DataBean> CREATOR = new Parcelable.Creator<DataBean>() {
            @Override
            public DataBean createFromParcel(Parcel source) {
                return new DataBean(source);
            }

            @Override
            public DataBean[] newArray(int size) {
                return new DataBean[size];
            }
        };
    }
}
